package io;

import java.io.FileNotFoundException;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.OutputStreamWriter;
import java.nio.charset.StandardCharsets;

public class OSWDemo {
    public static void main(String[] args) throws IOException {
        FileOutputStream fos=new FileOutputStream("osw.txt",true);
        //字节流就是直接传字符进去
        OutputStreamWriter osw=new OutputStreamWriter(fos, StandardCharsets.UTF_8);
        String line="super idol的笑容都没你的甜";
        osw.write(line);


        osw.write("八月正午的阳光都没你耀眼");

        System.out.println("写出完毕！");
        osw.close();


    }
}
